package frame;

import java.awt.BorderLayout;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;

import javax.swing.JButton;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;

import Client.MyClient;

public class Match extends JPanel {
	private MyClient mClient = null;
	private JButton btnNewButton;
	/**
	 * Create the panel.
	 * @param mClient 
	 */
	public Match(MyClient mClient) {
		this.mClient=mClient;
		this.setBorder(new EmptyBorder(5, 5, 5, 5));
		this.setLayout(null);
		//setLocationRelativeTo(null);
		btnNewButton = new JButton("开始匹配");
		btnNewButton.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				mClient.Match();
				btnNewButton.setEnabled(false);
			}
		});
		btnNewButton.setBounds(538, 439, 231, 110);
		this.add(btnNewButton,BorderLayout.CENTER);
	}

}
